package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.TVideoLikeMapper;
import com.ruoyi.system.domain.TVideoLike;
import com.ruoyi.system.service.ITVideoLikeService;

/**
 * 视频点赞Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-09-24
 */
@Service
public class TVideoLikeServiceImpl implements ITVideoLikeService 
{
    @Autowired
    private TVideoLikeMapper tVideoLikeMapper;

    /**
     * 查询视频点赞
     * 
     * @param userId 视频点赞主键
     * @return 视频点赞
     */
    @Override
    public TVideoLike selectTVideoLikeByUserId(Long userId)
    {
        return tVideoLikeMapper.selectTVideoLikeByUserId(userId);
    }

    /**
     * 查询视频点赞列表
     * 
     * @param tVideoLike 视频点赞
     * @return 视频点赞
     */
    @Override
    public List<TVideoLike> selectTVideoLikeList(TVideoLike tVideoLike)
    {
        return tVideoLikeMapper.selectTVideoLikeList(tVideoLike);
    }

    /**
     * 新增视频点赞
     * 
     * @param tVideoLike 视频点赞
     * @return 结果
     */
    @Override
    public int insertTVideoLike(TVideoLike tVideoLike)
    {
        return tVideoLikeMapper.insertTVideoLike(tVideoLike);
    }

    /**
     * 修改视频点赞
     * 
     * @param tVideoLike 视频点赞
     * @return 结果
     */
    @Override
    public int updateTVideoLike(TVideoLike tVideoLike)
    {
        return tVideoLikeMapper.updateTVideoLike(tVideoLike);
    }

    /**
     * 批量删除视频点赞
     * 
     * @param userIds 需要删除的视频点赞主键
     * @return 结果
     */
    @Override
    public int deleteTVideoLikeByUserIds(Long[] userIds)
    {
        return tVideoLikeMapper.deleteTVideoLikeByUserIds(userIds);
    }

    /**
     * 删除视频点赞信息
     * 
     * @param userId 视频点赞主键
     * @return 结果
     */
    @Override
    public int deleteTVideoLikeByUserId(Long userId)
    {
        return tVideoLikeMapper.deleteTVideoLikeByUserId(userId);
    }
}
